package pe.edu.upc.xcode.food.dao.impl;

import java.util.List;

import javax.persistence.EntityManager;
import javax.persistence.PersistenceContext;

import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Transactional;

import pe.edu.upc.xcode.food.dao.LocalDAO;
import pe.edu.upc.xcode.food.domain.Local;
@Repository
@Transactional
public class LocalDAOImpl implements LocalDAO{

    @PersistenceContext
    private EntityManager em;
	
	public LocalDAOImpl() {
		// TODO Auto-generated constructor stub
	}

	public Integer save(Local object) {
		// TODO Auto-generated method stub
		em.persist(object);
		return 1;
	}

	public Integer update(Local object) {
		// TODO Auto-generated method stub
		em.merge(object);
		return 1;
	}

	public Integer detele(Local object) {
		// TODO Auto-generated method stub
		return null;
	}

	public Local find(Local object) {
		// TODO Auto-generated method stub
		return null;
	}

	public List<Local> findAll() {
		// TODO Auto-generated method stub
		return null;
	}

}
